package net.lzzy.practices.entities;

import lombok.Getter;
import lombok.Setter;

import javax.persistence.*;
import java.util.Date;

@Entity
@Getter
@Setter
public class Applicant extends BaseEntity{
    @Transient
    public static final int STATUS_APPLYING=0;

    @Transient
    public static final int STATUS_APPROVED=1;

    @Transient
    public static final int STATUS_DECLINED=2;

    private  int status;
    @Temporal(TemporalType.TIMESTAMP)
    private Date applyTime;
    @ManyToOne
    private User student;
    @ManyToOne
    private Course course;

    public Applicant() {
        applyTime=new Date();
    }
}
